class Cat:
    __name = '小猫' #私有属性进行封装
    def print(self):
        print('我是私有方法')
        print(self.__name)

cat = Cat()
cat.print()